﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true"
    CodeBehind="QLPhepCongTac.aspx.cs" Inherits="ChamCong.LanhDao.QLPhepCongTac" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
    <style type="text/css">
        div.childMenu
        {
            padding-bottom: 10px;
        }
        
        div.childMenu ul
        {
            list-style: none;
            margin: 0px;
            padding: 0px;
            width: auto;
        }
        
        div.childMenu ul li
        {
            padding-right: 5px;
        }
        
        div.childMenu ul li a
        {
            background-color: #D4D4D4;
            color: #525252;
            display: block;
            line-height: 1.35em;
            padding: 4px 10px;
            text-decoration: none;
            white-space: nowrap;
        }
        
        div.childMenu ul li a:hover
        {
            background-color: #3399FF;
            color: #FFF;
            text-decoration: none;
        }
        
        div.childMenu ul li a:active
        {
            background-color: #3399FF;
            color: #cfdbe6;
            text-decoration: none;
        }
        
        div.childMenu ul li a:visited
        {
            font-weight: bold;
        }
        div.childMenu ul li a.current
        {
            background-color: #3399FF;
            color: #FFF;
        }
    </style>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="MainContent" runat="server">
    <asp:ScriptManager ID="ScriptManager1" runat="server">
    </asp:ScriptManager>
    <asp:Menu ID="Menu1" runat="server" Orientation="Horizontal" CssClass="childMenu"
        SkipLinkText="">
        <Items>
            <asp:MenuItem Text="DS phép chờ duyệt" Value="" NavigateUrl="~/LanhDao/QLPhepCongTac.aspx?ThaoTac=DSChoDuyet">
            </asp:MenuItem>
            <asp:MenuItem Text="DS phép đã duyệt" Value="" NavigateUrl="~/LanhDao/QLPhepCongTac.aspx?ThaoTac=DSDaDuyet">
            </asp:MenuItem>
            <asp:MenuItem Text="DS phép không duyệt" Value="" NavigateUrl="~/LanhDao/QLPhepCongTac.aspx?ThaoTac=DSKhongDuyet">
            </asp:MenuItem>
        </Items>
    </asp:Menu>
    <sbc:sbcMsgBox ID="sbcMsgBox4" runat="server" UseJQuery="True" />
    <div>
        <div style="float: left;">
<%--            <asp:UpdatePanel ID="UpdatePanel1" runat="server">
                <ContentTemplate>--%>
                    <asp:GridView ID="grvDSPhepCT" runat="server" CellPadding="4" ForeColor="#333333"
                        GridLines="None" AutoGenerateColumns="False" EmptyDataText="Hiện thời không có dữ liệu."
                        AllowPaging="True" PageSize="8" OnPageIndexChanging="grvDSPhepCT_PageIndexChanging">
                        <AlternatingRowStyle BackColor="White" />
                        <Columns>
                            <asp:BoundField DataField="MaPhepCT" HeaderText="Mã phép" />
                            <asp:BoundField DataField="MaNV" HeaderText="Mã NV" />
                            <asp:BoundField DataField="HoTen" HeaderText="Họ Tên" />
                            <asp:BoundField DataField="NgayDi" DataFormatString="{0:dd/MM/yyyy}" HeaderText="Ngày đi" />
                            <asp:BoundField DataField="NgayLamViecLai" DataFormatString="{0:dd/MM/yyyy}" HeaderText="Ngày làm lại" />
                            <asp:BoundField DataField="SoNgayCT" HeaderText="Số ngày CT">
                                <HeaderStyle Width="35px" HorizontalAlign="Center" />
                            </asp:BoundField>
                            <asp:TemplateField HeaderText="Trạng thái">
                                <ItemTemplate>
                                    <asp:Label ID="lblTrangThaiDuyet" runat="server" Text='<%# ktDuyet(Eval("TrangThaiDuyet")) %>'></asp:Label>
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:BoundField DataField="NgayTao" DataFormatString="{0:dd/MM/yyyy}" HeaderText="Ngày Tạo" />
                            <asp:TemplateField HeaderText="Xem">
                                <ItemTemplate>
                                    <a href='QLPhepCongTac.aspx?ThaoTac=<%# LayLoaiDS() %>&MaPhepCT=<%# Eval("MaPhepCT") %>'>
                                        Xem</a>
                                </ItemTemplate>
                            </asp:TemplateField>
                        </Columns>
                        <EditRowStyle BackColor="#2461BF" />
                        <FooterStyle BackColor="#0072c6" Font-Bold="True" ForeColor="White" />
                        <HeaderStyle BackColor="#0072c6" Font-Bold="True" ForeColor="White" />
                        <PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" CssClass="pager" />
                        <RowStyle BackColor="#EFF3FB" HorizontalAlign="Center" />
                        <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
                        <SortedAscendingCellStyle BackColor="#F5F7FB" />
                        <SortedAscendingHeaderStyle BackColor="#6D95E1" />
                        <SortedDescendingCellStyle BackColor="#E9EBEF" />
                        <SortedDescendingHeaderStyle BackColor="#4870BE" />
                    </asp:GridView>
<%--                </ContentTemplate>
            </asp:UpdatePanel>--%>
        </div>
        <div style="float: left; padding-left: 20px;">
<%--            <asp:UpdatePanel ID="UpdatePanel2" runat="server">
                <ContentTemplate>--%>
                    <asp:DetailsView ID="dtvCTPhepCT" runat="server" Height="50px" Width="220px" Visible="False"
                        AutoGenerateRows="False" BackColor="LightGoldenrodYellow" BorderColor="Tan" BorderWidth="1px"
                        CellPadding="2" ForeColor="Black" GridLines="None">
                        <AlternatingRowStyle BackColor="PaleGoldenrod" />
                        <EditRowStyle BackColor="DarkSlateBlue" ForeColor="GhostWhite" />
                        <Fields>
                            <asp:TemplateField HeaderText="Tên nhân viên">
                                <ItemTemplate>
                                    <asp:Label ID="lblTenNV" runat="server" Text='<%# ktTenNV(Eval("MaNV")) %>'></asp:Label>
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:BoundField DataField="MaNV" HeaderText="Phòng ban" />
                            <asp:BoundField DataField="NgayDi" DataFormatString="{0:dd/MM/yyyy}" HeaderText="Ngày đi" />
                            <asp:BoundField DataField="NgayLamViecLai" DataFormatString="{0:dd/MM/yyyy}" HeaderText="Ngày làm" />
                            <asp:BoundField DataField="ChiTiet" HeaderText="Nội dung" />
                            <asp:BoundField DataField="SoNgayCT" HeaderText="Số ngày công tác" />
                            <asp:BoundField DataField="NgayTao" DataFormatString="{0:dd/MM/yyyy}" HeaderText="Ngày tạo" />
                            <asp:TemplateField HeaderText="Trạng thái">
                                <ItemTemplate>
                                    <asp:Label ID="lblTrangThaiDuyet" runat="server" Text='<%# ktDuyet(Eval("TrangThaiDuyet")) %>'></asp:Label>
                                </ItemTemplate>
                            </asp:TemplateField>
                        </Fields>
                        <FooterStyle BackColor="Tan" />
                        <HeaderStyle BackColor="Tan" Font-Bold="True" />
                        <PagerStyle BackColor="PaleGoldenrod" ForeColor="DarkSlateBlue" HorizontalAlign="Center" />
                    </asp:DetailsView>
                    <asp:Label ID="lblChuThich" runat="server" Text="Phản hồi:" Visible="False" ForeColor="#FF6600"
                        Font-Italic="True" Font-Bold="True"></asp:Label>
                    <br />
                    <asp:TextBox ID="tbxChuThich" runat="server" Height="71px" TextMode="MultiLine" Visible="False"></asp:TextBox>
                    <br />
                    <div>
                        <asp:Button class="button" ID="btnDuyet" runat="server" Text="Duyệt" OnClick="btnDuyet_Click"
                            Visible="False" />
                        <asp:Button class="button" ID="btnKhongDuyet" runat="server" Text="Không duyệt" OnClick="btnKhongDuyet_Click"
                            Visible="False" />
                        <asp:Button class="button" ID="btQuayLai" runat="server" Text="Quay lại" Visible="False" />
                    </div>
<%--                </ContentTemplate>
            </asp:UpdatePanel>--%>
        </div>
    </div>
</asp:Content>
